package cn.iocoder.yudao.module.bk.controller.admin.lwbook.vo;

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDate;
import java.time.LocalDateTime;

@Schema(description = "管理后台 - 来往书籍 Response VO")
@Data
@ExcelIgnoreUnannotated
public class LwBookRespVO {

    @Schema(description = "编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "17143")
    @ExcelProperty("编号")
    private Long id;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

    @Schema(description = "书名", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("书名")
    private String title;

    @Schema(description = "封面图")
    private String img;

    @Schema(description = "简介")
    private String summary;

    @Schema(description = "isbn编号")
    @ExcelProperty("isbn编号")
    private String isbn;

    @Schema(description = "出版社")
    @ExcelProperty("出版社")
    private String publisher;

    @Schema(description = "出版时间")
    @ExcelProperty("出版时间")
    private String pubDate;

    @Schema(description = "出版年限")
    @ExcelProperty("出版年限")
    private LocalDate pubYear;

    @Schema(description = "页数", example = "3697")
    @ExcelProperty("页数")
    private Integer pageCount;

    @Schema(description = "流程状态", example = "0")
    @ExcelProperty(value = "流程状态", converter = DictConvert.class)
    @DictFormat("bk_book_apply_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private String applyStatus;

    @Schema(description = "入库状态", example = "0")
    @ExcelProperty(value = "入库状态", converter = DictConvert.class)
    @DictFormat("bk_book_store_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private String storeStatus;

    @Schema(description = "入库时间")
    @ExcelProperty("入库时间")
    private LocalDateTime storeTime;

    @Schema(description = "捐献人id", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("捐献人id")
    private Long donor;

    @Schema(description = "捐献人名称", example = "你说的对")
    @ExcelProperty("捐献人名称")
    private String donorName;

    @Schema(description = "当前持有人id")
    @ExcelProperty("当前持有人id")
    private Long nowHolder;

    @Schema(description = "当前持有人")
    @ExcelProperty("当前持有人")
    private String nowHolderName;
    @Schema(description = "备注", example = "你说的对")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "合规出版社", example = "合规出版社")
    @ExcelProperty("合规出版社")
    private Boolean compliance;

}
